package com.hrms.dao;

import com.hrms.pojo.ContractManage;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author LK
 * @since 2021-10-19
 */
public interface ContractManageMapper extends BaseMapper<ContractManage> {
    @Select("select id,staff_id,contract_begin_date,contract_end_date,staff_post,contract_content,remarks WHERE staff_id=(SELECT staff_id FROM emp_information WHERE staff_name=#{name})")
    List<ContractManage> selectByName(String name);

    int deleteByStaffId(Integer a);
    @Select("select * from contract_manage")
    List<ContractManage> selUserMapper();
}
